-
Notifications
You must be signed in to change notification settings - Fork 3
[feat] 유저 닉네임을 통해 랭킹 조회 #91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
backend/src/main/java/io/f1/backend/domain/stat/app/StatService.java
Outdated
Show resolved
Hide resolved
| @Query("SELECT s.score FROM Stat s WHERE s.user.nickname = :nickname") | ||
| Optional<Long> findScoreByNickname(String nickname); | ||
|
|
||
| long countByScoreGreaterThan(Long score); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이런것도 있군요?,? 하나 배워갑니다 .. 🙂
| FROM | ||
| Stat s JOIN s.user u | ||
| """) | ||
| Page<StatWithNickname> findWithUser(Pageable pageable); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이런 커스텀 쿼리메소드는 jpa와 달리 findAllStatsWithUser 이런식으로 대상을 확실히 표시해주는건 어떨까 싶습니다!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
좋은 의견 감사합니다!
항상 메서드 명을 정하는 게 어려운 것 같아요,,
수정 반영하겠습니다!
sehee123
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고하셨습니다!
저도 dbRider 테스트 적용 부분 얼른 따라해봐야겠네요 👀
jiwon1217
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨습니다 !
LimKangHyun
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨습니다!
silver-eunjoo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨습니다!
🛰️ Issue Number
🪐 작업 내용
native query를 사용하면 1-2번 과정의 통합이 가능하지만, 아래와 같은 이유로 native query를 사용하지 않았습니다.
위 일련의 과정에 대해서는 Redis 리팩토링 시에 효율적인 방법을 찾아보도록 하겠습니다.
📚 Reference
✅ Check List